<!DOCTYPE html>
<html>

<head>
    <meta charset="UTF-8">
    <title>{:session('cp.cpsysname')}--系统管理平台</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <meta name="description" content="{:config('webconfig.description');}">
    <meta name="keywords" content="{:config('webconfig.keywords');}">
    <meta name="author" content="runoob">
    <link rel="stylesheet" href="__STATIC_URL__/static/css/bootstrap.css">
    <link rel="stylesheet" type="text/css" href="__STATIC_URL__/static/css/index.css"/>
    <script src="__STATIC_URL__/static/js/jquery-2.1.4.min.js"></script>
    <script src="__STATIC_URL__/static/bootstrap/3.3.7/js/bootstrap.min.js"></script>
    <script src="__STATIC_URL__/static/layer/layer.js"></script>
</head>
<style>
    .img-responsive {
        display: block;
        max-width: 100% !important;
        height: auto !important;
    }
    .adminex-form .col-sm-9{
        padding-right: 30px;
        padding-left: 0;
    }
</style>
<body>
{include file='public/header'/}
<section>
    <!------------------导航-------------------------->
    {include file='public/left'/}
    <!--------------------------主要内容区域------------------------------------->
    <div class="content">
        <div class="page-heading mgl15 mgr15">
            <ul class="breadcrumb">
                <li>当前位置是:</li>
                <li><a href="{:url('momach/momachlist')}">商户管理</a></li>
                <li><a href="javascript:history.back();">进件审核</a></li>
                <li class="active" style="color: #02b87f;">进件审核</li>
            </ul>
        </div>
        <div class="mgl15 mgr15">
            <ul id="myTab" class="nav nav-tabs mgb10">
                <li class="active">
                    <a class="fsz14" href="#Message" data-toggle="tab">基础信息</a>
                </li>
            </ul>
            <div id="myTabContent" class="tab-content">
                <div class="tab-pane fade in active" id="Message">

                    <table class="table table-bordered">
                        <caption>基础信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">商户性质</td>
                            <td>{switch name="info['merchClass']" }
                                {case value="1"}企业商户{/case}
                                {case value="2"}个体商户{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">商户类型</td>
                            <td>{switch name="info['merchType']" }
                                {case value="1"}连锁商户{/case}
                                {case value="2"}单店{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">关联商户号</td>
                            <td>{$info['relatedMerchName']}</td>
                        </tr>
                        <tr>
                            <td class="active">商户注册名称</td>
                            <td>{$info['merchName']}</td>
                            <td class="active">商户简称</td>
                            <td>{$info['merchShortName']}</td>
                            <td class="active">小票名称</td>
                            <td>{$info['userDefinedName']}</td>
                        </tr>
                        <tr>
                            <td class="active">注册地址</td>
                            <td colspan="5"> (省:){$info['regProvId']}  (市:) {$info['regCityId']}    (县/区:) {$info['regAreaId']}  (详细地址:) {$info['regAddr']}    </td>

                        </tr>
                        <tr>
                            <td class="active">经营场所地址</td>
                            <td colspan="5"> (省:){$info['provId']}  (市:) {$info['cityId']}    (县/区:) {$info['areaId']}  (详细地址:) {$info['merchAddr']}    </td>
                        </tr>
                        <tr>
                            <td class="active">营业时间</td>
                            <td colspan="5">{$info['businessShours']}-{$info['businessEhours']}</td>
                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>代理商信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">代理商名称</td>
                            <td colspan="3">{:getagentname($info['agentid'])}</td>
                            <td class="active"></td>
                            <td></td>
                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>营业资质</caption>
                        <tbody>
                        <tr>
                            <td class="active">是否三证合一</td>
                            <td>{switch name="info['isCreditCode']" }
                                {case value="0"}否{/case}
                                {case value="1"}是{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">统一社会信用代码证</td>
                            <td>{$info['creditCode']}</td>
                            <td class="active">商户经营类型</td>
                            <td>{switch name="info['cateType']" }
                                {case value="1"}实体{/case}
                                {case value="2"}虚拟{/case}
                                {default /}未知
                                {/switch}</td>
                        </tr>
                        <tr>
                            <td class="active">证件有效期类型</td>
                            <td colspan="2">
                                {switch name="info['licType']" }
                                {case value="1"}非长期{/case}
                                {case value="2"}长期{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">证件有效期</td>
                            {switch name="info['licType']" }
                            {case value="1"} <td colspan="2">{$info['licSdate']}-{$info['licEdate']}</td>{/case}
                            {case value="2"} <td colspan="2">{$info['licSdate']}-长期</td>{/case}
                            {default /} <td colspan="2"></td>
                            {/switch}
                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>法人信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">法人姓名</td>
                            <td>{$info['legalName']}</td>
                            <td class="active">证件类型</td>
                            <td colspan="3">
                                {switch name="info['idType']" }
                                {case value="01"}身份证{/case}
                                {case value="02"}护照{/case}
                                {case value="03"}港澳台通行证{/case}
                                {case value="04"}军官证{/case}
                                {case value="05"}回乡证{/case}
                                {case value="06"}工商登记号{/case}
                                {case value="09"}其他{/case}
                                {default /}未知
                                {/switch}</td>
                        </tr>
                        <tr>
                            <td class="active">证件号码</td>
                            <td>{$info['idNo']}</td>
                            <td class="active">证件有效期类型</td>
                            <td>
                                {switch name="info['idValidType']" }
                                {case value="1"}非长期{/case}
                                {case value="2"}长期{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">证件有效期</td>
                            {switch name="info['idValidType']" }
                            {case value="1"} <td>{$info['idSdate']}-{$info['idEdate']}</td>{/case}
                            {case value="2"} <td>{$info['idSdate']}-长期</td>{/case}
                            {default /} <td></td>
                            {/switch}
                        </tr>
                        </tbody>

                    </table>
                    <table class="table table-bordered">
                        <caption>联系人信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">联系人姓名</td>
                            <td>{$info['contactName']}</td>
                            <td class="active">证件类型</td>
                            <td colspan="3">
                                {switch name="info['contactIdType']" }
                                {case value="01"}身份证{/case}
                                {case value="02"}护照{/case}
                                {case value="03"}港澳台通行证{/case}
                                {case value="04"}军官证{/case}
                                {case value="05"}回乡证{/case}
                                {case value="06"}工商登记号{/case}
                                {case value="09"}其他{/case}
                                {default /}未知
                                {/switch}</td>
                        </tr>
                        <tr>
                            <td class="active">证件号码</td>
                            <td>{$info['contactIdNo']}</td>
                            <td class="active">证件有效期类型</td>
                            <td>
                                {switch name="info['contactIdValidType']" }
                                {case value="1"}非长期{/case}
                                {case value="2"}长期{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">证件有效期</td>
                            {switch name="info['contactIdValidType']" }
                            {case value="1"} <td colspan="2">{$info['contactIdSdate']}-{$info['contactIdEdate']}</td>{/case}
                            {case value="2"} <td colspan="2">{$info['contactIdSdate']}-长期</td>{/case}
                            {default /} <td colspan="2"></td>
                            {/switch}
                        </tr>
                        <tr>
                            <td class="active">联系人手机</td>
                            <td colspan="2">{$info['contactTelno']}</td>
                            <td class="active">联系人邮箱</td>
                            <td colspan="2">{$info['contactEmail']}</td>


                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>结算信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">结算账户类型</td>
                            <td>{switch name="info['isPrivate']" }
                                {case value="0"}对公{/case}
                                {case value="1"}对私{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">结算账户名</td>
                            <td>{$info['bankActName']}</td>
                            <td class="active">结算账号</td>
                            <td>{$info['bankActId']}</td>
                        </tr>
                        <tr>
                            <td class="active">银行所在省</td>
                            <td>{$info['bankProvId']}</td>
                            <td class="active">银行所在市</td>
                            <td>{$info['bankCityId']}</td>
                            <td class="active">银行所在县/区</td>
                            <td>{$info['bankAreaId']}</td>
                        </tr>
                        <tr>
                            <td class="active">银行名称</td>
                            <td colspan="5">{$info['bankName']}</td>
                        </tr>
                        <tr>
                            <td class="active">结算周期</td>
                            <td colspan="5">
                                {switch name="info['settleTerm']" }
                                {case value="1"}T+1{/case}
                                {case value="2"}D+1{/case}
                                {default /}未知
                                {/switch}
                            </td>

                        </tr>
                        {if condition="$info['settleTerm'] eq 2"}
                        <tr>
                            <td class="active">D+1结算费率（%）</td>
                            <td colspan="5">
                             {$info['fee01']}
                            </td>

                        </tr>
                        {/if}
                    {if condition="$info['merchClass'] eq 2"}
                        <tr>
                            <td class="active">持卡人证件类型</td>
                            <td colspan="3">
                                {switch name="info['accountIdType']" }
                                {case value="01"}身份证{/case}
                                {case value="02"}护照{/case}
                                {case value="03"}港澳台通行证{/case}
                                {case value="04"}军官证{/case}
                                {case value="05"}回乡证{/case}
                                {case value="06"}工商登记号{/case}
                                {case value="09"}其他{/case}
                                {default /}未知
                                {/switch}</td>
                        </tr>
                        <tr>
                            <td class="active">证件号码</td>
                            <td>{$info['accountIdNo']}</td>
                            <td class="active">证件有效期类型</td>
                            <td>
                                {switch name="info['accountIdValidType']" }
                                {case value="1"}非长期{/case}
                                {case value="2"}长期{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">证件有效期</td>
                            {switch name="info['accountIdValidType']" }
                            {case value="1"} <td colspan="2">{$info['accountIdSdate']}-{$info['accountIdEdate']}</td>{/case}
                            {case value="2"} <td colspan="2">{$info['accountIdSdate']}-长期</td>{/case}
                            {default /} <td colspan="2"></td>
                            {/switch}
                        </tr>
                        {/if}
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>微信支付宝信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">是否开通微信支付</td>
                            <td> {switch name="info['auth18']" }
                                {case value="0"}否{/case}
                                {case value="1"}是{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">商户经营类目（微信）</td>
                            <td>{$info['wechatCateCode']}</td>
                            <td class="active">微信支付手续费（%）</td>
                            <td>{$info['fee08']}</td>

                        </tr>
                        <tr>
                            <td class="active">是否开通支付宝支付</td>
                            <td> {switch name="info['auth19']" }
                                {case value="0"}否{/case}
                                {case value="1"}是{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">商户经营类目（微信）</td>
                            <td>{$info['alipayCateCode']}</td>
                            <td class="active">支付宝支付手续费（%）</td>
                            <td>{$info['fee12']}</td>
                        </tr>
                        <tr>
                            <td class="active">是否开通小程序支付</td>
                            <td> {switch name="info['auth38']" }
                                {case value="0"}否{/case}
                                {case value="1"}是{/case}
                                {default /}未知
                                {/switch}</td>
                            <td class="active">微信小程序Appid</td>
                            <td>{$info['wxAppid']}</td>
                            <td class="active">微信小程序费率（%）</td>
                            <td>{$info['fee33']}</td>
                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <caption>证件图片信息</caption>
                        <tbody>
                        <tr>
                            <td class="active">营业执照</td>
                            <td><img src="{$info['archFlph01']}"></td>
                            <td class="active">开户许可证</td>
                            <td><img src="{$info['archFlph04']}"></td>

                        </tr>
                        <tr>
                            <td class="active">法人身份证正面</td>
                            <td><img src="{$info['archFlph05']}"></td>
                            <td class="active">法人身份证反面</td>
                            <td><img src="{$info['archFlph06']}"></td>
                        </tr>
                        </tbody>
                    </table>
                    <table class="table table-bordered">
                        <tbody>
                        <tr>
                            <td><button type="button" class="btn btn-primary" onclick="setinfo('query')">确认提交</button></td>
                            <td><button type="button" class="btn btn-danger"  data-toggle="modal" data-target="#myModal">驳回请求</button></td>

                        </tr>

                        </tbody>
                    </table>
                </div>
            </div>
        </div>
        <!-- 模态框（Modal） -->
        <div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
            <div class="modal-dialog">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
                            &times;
                        </button>
                        <h4 class="modal-title" id="myModalLabel">
                            驳回原因
                        </h4>
                    </div>
                    <div class="modal-body">
                       <textarea id="remark" cols="70" rows="10"></textarea>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭
                        </button>
                        <button type="button" class="btn btn-primary" onclick="setinfo('cancel')">
                            提交
                        </button>
                    </div>
                </div><!-- /.modal-content -->
            </div><!-- /.modal -->
        </div>
        {include file='public/footer'/}
    </div>
</section>

</body>
<script type="text/javascript">
    function setinfo(param) {
        $.ajax({
            type: "POST",
            url: "{:url('')}",
            async: false,
            data:{
              id:"{$info['id']}",
              method:param,
              remark:$('#remark').val(),
            },
            success: function (res) {
                console.log(res);
                if(res.result_code=="SUCCESS"){
                    layer.msg(res.result_msg,{icon:1})
                }else{
                    layer.msg(res.result_msg,{icon:1})
                }
                // if(data.code==0){
                //     layer.msg("成功",{icon:1});
                //     $('#myModal2').modal('hide');
                //     setTimeout("window.location.reload()",500);
                // }else{
                //     layer.alert(data.message);
                //     return false;
                // }
            }
        });
    }

</script>

</html>